import request from '@/utils/request'

// 分页查询账号
export function getAccountPage(params: any) {
  return request.get('/api/staff/account/page', { params })
}

// 新增账号
export function addAccount(data: any) {
  return request.post('/api/staff/account', data)
}

// 编辑账号
export function updateAccount(data: any) {
  return request.put('/api/staff/account', data)
}

// 删除账号
export function deleteAccount(userId: number) {
  return request.delete(`/api/staff/account/${userId}`)
}

// 更新账号状态
export function updateAccountStatus(userId: number, status: number) {
  return request.put(`/api/staff/account/status/${userId}?status=${status}`)
} 